import axios from '../network/index'
import qs from "qs"

// 获取设备列表
export function getDeviceList(params) {
  return axios.get('/Face/Authorize/getDeviceList', params)
}
//   获取识别记录
export function getFaceRecord(params) {
  return axios.get('/Face/FaceRecord/getFaceRecord', params)
}
//   获取周计划列表
export function getWeekPlanList(params) {
  return axios.get('/Face/WeekPlan/getWeekPlanList', params)
}

// 新增和修改周计划
export function saveWeekPlan(params) {
  return axios.post('/Face/WeekPlan/saveWeekPlan', qs.stringify(params))
}

// 删除周计划
export function delWeekPlan(params) {
  return axios.post('/Face/WeekPlan/delWeekPlan', qs.stringify(params))
}

//获取人脸授权人员信息列表
export function getAuthorizeList(params) {
  return axios.get('/Face/Authorize/getAuthorizeList', params)
}

// 获取人脸建模人员信息
export function getPeopleList(params) {
  return axios.get('/Face/Modeling/getPeopleList', params)
}

// 获取权限组列表
export function getAuthGroupList(params) {
  return axios.get('/Face/AuthGroup/getAuthGroupList', params)
}

//  删除权限组
export function delAuthGroup(params) {
  return axios.post('/Face/AuthGroup/delAuthGroup', qs.stringify(params))
}

//获取设备配置权限组信息
export function getAuthGroupCfg(params) {
  return axios.get('/Face/AuthGroupCfg/getAuthGroupCfg', params)
}

export function delDevAuthGroup(params) {
  return axios.post('/Face/AuthGroupCfg/delGroupCfg', qs.stringify(params))
}

// 权限组重新下载
export function getCfgRedown(params) {
  return axios.post('/Face/AuthGroupCfg/redown', qs.stringify(params))
}

//添加权限配置
export function getAddGroupCfg(params) {
  return axios.post('/Face/AuthGroupCfg/addGroupCfg', qs.stringify(params))
}

// 人员绑定重新下载
export function getRedown(params) {
  return axios.post('/Face/AuthGroupAccess/redown', qs.stringify(params))
}

//  添加权限组
export function saveAuthGroup(params) {
  return axios.post('/Face/AuthGroup/saveAuthGroup', qs.stringify(params))
}

export function getGroupAccessList(params) {
  return axios.get('/Face/AuthGroupAccess/getGroupAccessList', params)
}

export function getDelGroupAccess(params) {
  return axios.post('/Face/AuthGroupAccess/delGroupAccess', qs.stringify(params))
}
//  导出
export function Faceexport(params) {
  return axios.post('/Face/FaceRecord/export', qs.stringify(params))
}
// 获取人员信息列表
export function getStaffOrStudInfoList(params) {
  return axios.get('/StaffOrStudInfo/getStaffOrStudInfoList', params)
}
// 获取识别记录
export function getRecordList(params) {
  return axios.get('/Face/AlleywayRecords/getRecordList', params)
}
// 获取进出记录分析
export function getLeaveAnalysisList(params) {
  return axios.get('/accesscontrol/records/leaveAnalysis/getLeaveAnalysisList', params)
}

//  识别记录导出
export function exportExce(params) {
  return axios.post('/Face/AlleywayRecords/export', qs.stringify(params))
}

//  加入黑名单
export function addBlackName(params) {
  return axios.post('/Face/AlleywayRecords/addBlackName', qs.stringify(params))
}

//  进出情况分析导出
export function exportLoginin(params) {
  return axios.post('/accesscontrol/records/leaveAnalysis/export', qs.stringify(params))
}

//  进出记录分析
export function analysisDaily(params) {
  return axios.post('/accesscontrol/records/leaveAnalysis/analysisDaily', qs.stringify(params))
}

//保存授权
export function saveGroupAccess(params) {
  return axios.post('/Face/AuthGroupAccess/saveGroupAccess', qs.stringify(params))
}
//  进出记录分析
export function redown(params) {
  return axios.post('/Face/Authorize/redown', qs.stringify(params))
}


export function getWidgetComboboxList(params) {
  return axios.get('/SysDictionary/getWidgetComboboxList', params)
}

//  保存授权
export function saveAuthorize(params) {
  return axios.post('/Face/Authorize/saveAuthorize', qs.stringify(params))
}
//  删除授权
export function delAuthorize(params) {
  return axios.post('/Face/Authorize/delAuthorize', qs.stringify(params))
}
// 获取时段列表
export function getTimeSchemeList(params) {
  return axios.get('/Face/TimeScheme/getTimeSchemeList', params)
}

//  保存和更改时段
export function saveTimeScheme(params) {
  return axios.post('/Face/TimeScheme/saveTimeScheme', qs.stringify(params))
}
//  删除时段
export function deleteTimeScheme(params) {
  return axios.post('/Face/TimeScheme/deleteTimeScheme', qs.stringify(params))
}
//  修改通行时段
export function updateTimeScheme(params) {
  return axios.post('/Face/Authorize/updateTimeScheme', qs.stringify(params))
}
//  导出数据
export function exportInfoFace(params) {
  return axios.post('/Face/Modeling/exportInfoFace', qs.stringify(params))
}
//  清除人脸
export function clearFace(params) {
  return axios.post('/Face/Modeling/clearFace', qs.stringify(params))
}

//  压缩包图片上传
export function batchUploadFace(params) {
  return axios.post('/Face/Modeling/batchUploadFace', qs.stringify(params))
}
//  上传照片
export function uploadFace(params) {
  return axios.post('/Face/Modeling/uploadFace', qs.stringify(params))
}

// 获取建模信息
export function getModeling(params) {
  return axios.get('/Face/Modeling/getModeling', params)
}
